package com.xiongda.service;

import com.xiongda.common.ServerResponse;
import com.xiongda.pojo.Blog;
import com.xiongda.pojo.BlogWithBLOBs;

/**
 * 博客服务层接口
 *
 * @author 缪琼
 */
public interface BlogService {

    /**
     * 获取博客详情
     * @param id
     * @return
     */
    ServerResponse getBlog(Long id);

    /**
     * 获取用户底下所有的博客
     * @param userId
     * @param pageNo
     * @param pageSize
     * @return
     */
    ServerResponse getBlogByUser(Long userId, Integer pageNo, Integer pageSize);

    /**
     * 新增或修改博客
     * @param blog
     * @return
     */
    ServerResponse saveAndEditBlog(BlogWithBLOBs blog);

}
